<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        var getD = new Promise(function(resolve){
            var count = 0;
            var start = new Date();
            for(var i=0;i<40000;i++){
                for(var j=0;j<40000;j++){
                    count++;
                }
            }
            var end = new Date();
            resolve(end-start);
        })
        async function fun(){
            var data = await getD;
            console.log(data);
        }
        fun();
        console.log("我是后面的");
        
    </script>
</body>
</html>